package com.libbase.mvp.presenter;

import com.chan.net.Result;
import com.libbase.bean.NyqfBean;
import com.libbase.http.Http;
import com.libbase.http.HttpTagInterceptorKt;

import io.reactivex.Flowable;


public class NewModel implements NewContract.Model {
    @Override
    public Flowable<Result<NyqfBean>> getNews(String nav) {
        return getHttp().getnyqfNews(nav);
    }

    @Override
    public NyqfContract.NyqfMvpApi getHttp() {
        return Http.getNyqfRetrofit(NyqfContract.NyqfMvpApi.class);
    }

    @Override
    public void destroy() {
        HttpTagInterceptorKt.cancelTag("raw/master/nyqf_data.json");
    }
}
